<template>
	<view>
		<view class="top"></view>
		<view class="info">
			<view class="all_price" @click="$router.push('/pages/user/settting/user_info')">
				<view>
					账户资料
				</view>
				<image src="../../../static/img/center/arrow.png" style="width:16rpx;height: 28rpx;" mode=""></image>
			</view>
			<view class="all_price">
				<view class="">
					消息推送
				</view>
				<u-switch space="1" activeColor="#f9ae3d" inactiveColor="rgb(230, 230, 230)">
				</u-switch>
			</view>
			<view class="all_price">
				<view class="">
					清除缓存
				</view>
				<view>
					5013.MB
				</view>
			</view>
			<view class="all_price">
				<view class="">
					意见反馈
				</view>
				<image src="../../../static/img/center/arrow.png" style="width:16rpx;height: 28rpx;" mode=""></image>
			</view>
			<view class="all_price">
				<view class="">
					关于我们
				</view>
				<image src="../../../static/img/center/arrow.png" style="width:16rpx;height: 28rpx;" mode=""></image>
			</view>
			<view class="all_price">
				<view class="">
					分享APP
				</view>
				<image src="../../../static/img/center/arrow.png" style="width:16rpx;height: 28rpx;" mode=""></image>
			</view>
		</view>
		<view class="order">
			<view class="get_order" @click="handleLogout">
				退出登录
			</view>
		</view>
	</view>
</template>

<script>
	import { account } from '@/api'
	export default {
		data() {
			return {

			}
		},
		methods: {
			async handleLogout() {
				let { msg, status } = await account.logout({})
				if (status) {
					uni.showToast({
						title: msg,
						icon: 'none',
						duration: 2000
					});
					uni.switchTab({
						url: '/pages/index/index'
					})
				}

			}
		}
	}
</script>

<style lang="scss">
	.top {
		background-color: #f4f4f4;
		width: 100%;
		height: 20rpx;
	}

	.info {
		padding: 0 21rpx;
	}

	.payment {
		display: flex;
		align-items: center;
		padding: 35rpx 0 37rpx 22rpx;
		border-bottom: 1px solid #ddd;

		.way {
			margin-left: 39rpx;
			color: #777;
			font-size: 28rpx;
		}

		image {
			width: 40rpx;
			height: 38rpx;
			margin-left: 32rpx;
		}
	}

	.store {
		background-color: #fff;
		display: flex;
		align-content: space-between;
		border-bottom: 1px solid #ddd;
		padding: 21rpx 0;

		image {
			width: 161rpx;
			height: 166rpx;
			margin-left: 30rpx;
			margin-right: 24rpx;
		}

		.remove {
			color: gray;
			margin-left: 90rpx;
			font-size: 20rpx;
		}

		.num {
			display: flex;
			margin-top: 30rpx;
			margin-bottom: 44rpx;

			text {
				margin-left: 40rpx;
				font-size: 24rpx;
				color: #999;
			}
		}
	}

	.all_price {
		display: flex;
		justify-content: space-between;
		border-bottom: 1px solid #ddd;
		padding: 35rpx 21rpx 39rpx 23rpx;
		font-size: 26rpx;
	}

	.mark {
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding: 20rpx 0 20rpx 21rpx;

		.input {
			width: 90%;
			border-bottom: 1px solid #ddd;
			font-size: 26rpx;
		}


	}

	.order {
		position: fixed;
		width: 100%;
		height: 97rpx;
		bottom: 170rpx;
		left: 0;
		display: flex;
		justify-content: space-between;
		align-items: center;

		.get_order {
			text-align: center;
			width: 90%;
			height: 100%;
			margin: 0 auto;
			line-height: 97rpx;
			font-size: 28rpx;
			color: #fff;
			background-color: #c55a5c;
			cursor: pointer;
			border-radius: 15rpx;
		}
	}
</style>